It is often desirable to identify and delineate segments of an image. Image segmentation is the process of partitioning an image into a set of non-overlapping parts, or segments, that together constitute the entire image. For example, the segmentation may divide the image into a background segment and a plurality of foreground segments. A foreground segment may, for example, correspond to an object, or a part of an object, in the image. Digital image or video processing may be facilitated by image segmentation.
In order to identify and delineate the segments in an image, the boundaries or edges of the segments may be detected or extracted. Extracting those edges or boundaries between segments using an electronically-implementable edge-detection algorithm or routine is difficult to do accurately for a general case. Such an algorithm must work for a wide range of images with varying amounts of scales and details. To be suitable for applications requiring fully-automated segmentation, the algorithm should not require user guidance or prior knowledge of the image to be segmented.
One technique for edge extraction is referred to as Canny edge detection. The process of conventional Canny edge detection begins with smoothing of intensity values by convolution with a two-dimensional Gaussian function. The smoothed image data is then differentiated to calculate a gradient vector function indicating the rate and direction of intensity change at each point in the image. Then, a non-maxima suppression process determines candidate edge points by eliminating non-maxima points perpendicular to edge directions. Subsequently, point-based thresholding is applied to the candidate edge points. In Canny edge detection, the point-based thresholding uses a hysteresis-type (two level) threshold function. Hysteresis-type threshold function evaluates the non-maxima points using two threshold levels. If a gradient value at a point lies above the upper threshold level, then the point is automatically accepted. If the gradient value lies below the lower threshold level, then the point is automatically rejected. If the gradient value lies in between the upper and lower thresholds, then the point is accepted if it is connected to a high value point. In other words, a chain does not stop until a point is reached that has a gradient value below the lower threshold.
Despite the accomplishments of prior edge extraction techniques, problems remain to be overcome in order to improve the edge extraction. One problem to be overcome to improve edge extraction is the over-identification of edges (i.e., the extraction of too many edges). For example, consider one white shirt on a black background. It may be desired to identify the white shirt as an image segment with a single edge around its boundary separating it from the black background segment. However, folds in the shirt may produce shadowed areas that may cause additional edges to be generated by the edge-detection routine. These extraneous edges may result in the creation of additional segments within the otherwise plain white shirt, or they may be superfluous in that they cannot be connected to enclose a segment.